angular.module('submitter',['api','degrees','data'])
.controller('submitterCtrl',['$scope','AsyncAPI','degreesService','dataService',function($scope,AsyncAPI,degreesService,dataService){
    $scope.degrees=degreesService.degrees;
    $scope.followers=dataService.followers;
    /*
    AsyncAPI.GetFollower().then(function(result){
        $scope.followers=result.data;
    });*/
    $scope.submit=function(){
        AsyncAPI.SaveRisk($scope.entry,$scope.description,$scope.posibility,$scope.influence,$scope.submitter,$scope.follower).then(function(){
            alert('Save successfully.');
        },function(error){
            alert(error);
        })
    }
}])